﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Globalization;
using DevExpress.XtraEditors;

namespace KhachSan.Process.Private.Bo.Class
{
    public class Tien
    {
        public static void setTextToCurrency(TextEdit text,long so)
        {
            NumberFormatInfo nfi = new NumberFormatInfo();
            nfi.CurrencySymbol = "";
            text.Text = string.Format(nfi, "0:C0", so);
        }
        public static void setTextToCurrency(LabelControl text, long so)
        {
            NumberFormatInfo nfi = new NumberFormatInfo();
            nfi.CurrencySymbol = "";
            text.Text = string.Format(nfi, "0:C0", so);
        }
        public static string setTextToCurrency( long so)
        {
            NumberFormatInfo nfi = new NumberFormatInfo();
            nfi.CurrencySymbol = "";
            return string.Format(nfi, "{0:C0}", so);
        }
    }
}
